const { info } = require("console");
var Radio=require("./radio.js");

var inforObj={
    "radioName":"PE",
    "pinlv":"87.66"
}

var radio =new Radio(inforObj);

radio.on("open",()=>{
    console.log(radio.radioName+"opened");
    console.log("lalalalalalla");
})

radio.on("close",()=>{
    console.log(radio.radioName+"closed")
})

setTimeout(()=>{
    radio.emit("open");
},2000);

setTimeout(()=>{
    radio.emit("close");
},2000);